package com.hitqz.robot.api.business.enums;

public enum RobotOtherCommandEnum {

    JACKING_UP( "jacking_up","顶升升起来", 0x17B6, 0, 0),

    SET_JACKING( "set_jacking","设置顶升", 0, 0, 0),

    SET_JACKING_ORIGIN( "set_jacking_origin","设置顶升回正", 0, 0, 0),

    JACKING_DOWN("jacking_down","顶升下降去", 0x17B7, 0, 0),

    JACKING_STATUS("jacking_status","请求顶升状态", 1027, 0, 0),
    BATCH_CALIBRATION("batch_calibration","批量标定点位",  0, 0, 0x6508),

    CLEAR_CALIBRATION("clear_calibration","清空标定点位",  0, 0, 0x6511),

    POWER_ON_OR_OFF("power_on_or_off","远程开关机",  0, 0, 0x6511),
    SET_WORK_MODE("set_work_mode","设置工作模式",  0, 0, 0x6511),

    SET_GF_FUNCTION("set_gf_function","设置光伏功能",  0, 0, 0),

    SET_GF_IO("set_gf_io","设置光伏IO使能",  0, 0, 0),
    SET_GF_RELAY("set_gf_relay","设置光伏继电器使能",  0, 0, 0),


    GET_SPEAK_REQUEST("speak_request","获取语音请求命令",  0x9999, 0, 0),

    SET_SPEAK_REQUEST("set_speak_request","设置语音请求命令",  0, 0, 0),

    REQ_CONTROLLER("req_controller","语音请求命令",  0, 0, 0),

    RE_LOCATION("relocation","机器人重定位",  0x07D2, 0, 0),

    VOICE_POWER("voice_power","音量控制",  0, 0x123, 0),

    AVOID_SWITCH("avoid_switch","激光雷达避障开关",  0, 0x12, 0),

    ROD_CONTROLLER("rodController","抢夺控制权",  0x0FA5, 0x12, 0),
    CANCEL_CONTROLLER("cancelController","释放控制权",  0x0FA6, 0x12, 0),

    CLEAR_ERROR_MESSAGE("clearError","清除机器人错误信息",  0x0FA9, 0, 0),

    WRITE_VAR("writeVar","写入变量数据",  0x00, 0x17, 0),
    READ_VAR("readVar","读取变量数据",  0x00, 0x19, 0),

    SET_DOOR_STATUS("switch_door","设置门禁开关状态",  0, 0, 0),

    GET_DOOR_STATUS("switch_door","获取门禁开关状态",  0, 0, 0),

    GO_HOME("go_home","一键返航",  0, 0, 0),
    GO_MILEAGE("go_mileage","前往指定里程",  0, 0, 0),

    RELOCATION("relocation","重定位",0,0,0),
    SET_LIGHT("set-light","设置补光灯",0,0,0),

    ;

    private String name;
    private String des;

    private int xgCommand;
    private int kcCommand;
    private int hitTrackCommand;

    RobotOtherCommandEnum(String name,String des, int xgCommand, int kcCommand, int hitTrackCommand) {
        this.name = name;
        this.des = des;
        this.xgCommand = xgCommand;
        this.kcCommand = kcCommand;
        this.hitTrackCommand = hitTrackCommand;
    }

    public static RobotOtherCommandEnum getByName(String cmdName) {
        for (RobotOtherCommandEnum cmdEnum : RobotOtherCommandEnum.values()) {
            if (cmdEnum.name.equals(cmdName)){
                return cmdEnum;
            }
        }
        return null;
    }

    public String getName() {
        return name;
    }

    public String getDes() {
        return des;
    }

    public int getXgCommand() {
        return xgCommand;
    }

    public int getKcCommand() {
        return kcCommand;
    }

    public int getHitTrackCommand() {
        return hitTrackCommand;
    }

}
